﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using ZhouYu.NewWorld.BLL.IService;
using ZhouYu.NewWorld.DAL;
using ZhouYu.NewWorld.Model;
using ZhouYu.NewWorld.ViewModel;

namespace ZhouYu.NewWorld.BLL.Service
{
    public class CategoryService : BaseRepository<Category>, ICategoryService
    {
        /// <summary>
        /// 查询所有父级组
        /// </summary>
        /// <returns></returns>
        public ResponseResult GetParentCategory()
        {
            ResponseResult result = new ResponseResult();

            result.data = QueryList(a => a.ParentId == 0);
            return result;
        }
    }
}
